/*
 * navy.h
 *
 *  Created on: 03.11.2012
 *      Author: Myrex
 */

#ifndef NAVY_H_
#define NAVY_H_

#define ROUGH_CYCL  1000
#define PRECI_CYCL  10000

//really not good
extern double quant_time;

typedef enum{

	navi_idle = 0,
	navi_rough,
	navi_prec_ready,
	navi_prec,
	navi_work

} navi_state_e;


typedef struct {
	double psi, theta, gamma, lat, lon;
	double i_psi, i_theta, i_gamma;//inertial orientations
	double igx, igy,igz;
} navi_t;

int navi_start();
int navi_step(navi_t *inf);

void navi_set_lat(double nlat);
void navi_set_lon(double nlon);
#endif /* NAVY_H_ */
